// 基于准备好的dom，初始化echarts实例
var salesChart = echarts.init(document.getElementById('sales-report'));

var option = {
    title: {
        text: '订单销售额度'
    },
    tooltip: {
        trigger: 'axis',
        axisPointer: {
            type: 'shadow'
        }
    },
    legend: {
        data: ['已支付', '未支付', '已关闭']
    },
    grid: {
        left: '3%',
        right: '4%',
        bottom: '3%',
        containLabel: true
    },
    xAxis: {
        type: 'value',
        boundaryGap: [0, 0.01]
    },
    yAxis: {
        type: 'category',
        data: ['2017/09','2017/08','2017/07','2017/06','2017/05','2017/10']
    },
    series: [
        {
            name: '已支付',
            type: 'bar',
            data: [182, 234, 290, 104, 144, 230]
        },
        {
            name: '未支付',
            type: 'bar',
            data: [125, 238, 300, 194, 141, 807]
        },
        {
            name: '已关闭',
            type: 'bar',
            data: [193, 238, 310, 121, 131, 607]
        }
    ]
};


// 使用刚指定的配置项和数据显示图表。
salesChart.setOption(option);